package Exception;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;

public class T {
    public static void main(String[] args) {
        System.out.println("程序开始了");

      FileOutputStream fos=null;
      try {
          fos=new FileOutputStream("./a/b/fos.dat");
          fos.write(1);
      }catch (IOException e){
          System.out.println("找到异常并解决");
      } finally {
          try {
              fos.close();
          }catch (Exception e){
              System.out.println("关闭流出现异常流");

          }
      }
        System.out.println("程序结束了");

    }
}
